﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Inter.MianShi.Model;
using Inter.MianShi.BLL;

namespace Inter.MianShi.Webfrom.Hander
{
    /// <summary>
    /// ShowCompany 的摘要说明
    /// </summary>
    public class ShowCompany : IHttpHandler
    {
        CompanyBll bll = new CompanyBll();
        /// <summary>
        /// 显示公司信息
        /// </summary>
        /// <param name="context"></param>
        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/plain";
            List<Company> list = bll.ShowCompany();
            Company c = new Company();
            string str = JsonHelper.JsonSerializer<List<Company>>(list);
            context.Response.Write(str);
        }

        public bool IsReusable
        {
            get
            {
                return false;
            }
        }
    }
}